#include "..\include\game_state\intro_state.h"
#include "..\include\game_manager.h"

int main()
{
	// Create the only GameManager instance in the application. The manager
	// holds a vector of all the opened GameStates (a state stack). It also
	// holds the only instaces of the GraphicsRenderer, SoundRenderer, and 
	// UserController, which it passes around to the GameStates.
	GameManager game;

	// Set the IntroState as the starting point. (Shows the logos of the game
	// engine and of the libraries being used.) The currently active state 
	// tells the GameManager when to change states.
	game.setStartState(IntroState::Instance());

	// GameManager::update() and render() updates/renders the currently active 
	// state (the last one in the state stack). The game stops when either the 
	// state stack is empty, or when the current GameState is the EndState.
	while (game.isRunning()) {
		game.update();
		game.render();
	}

	return 0;
}